package cn.gok.homework1;
import java.util.Scanner;
public class Homework {
        public static void main(String[] args) {
            产生并输出随机密码();
        }
    private static void 产生并输出随机密码() {
            for (int j = 0; j < 6; j++) {
                double rand = Math.random();
                double randTri = Math.random() * 3;
                if (randTri >= 0 && randTri < 1) {
                    System.out.print((char) (rand * ('9' - '0') + '0'));
                } else if (randTri >= 1 && randTri < 2) {
                    System.out.print((char) (rand * ('Z' - 'A') + 'A'));
                } else {
                    System.out.print((char) (rand * ('z' - 'a') + 'a'));
                }
            }

            System.out.println();

    }

}
